package com.kingwang.training.designpattern.adapter.bo;

/**
 * 符合美国电压标准的电饭煲
 * 现在要把它用在中国的220V电压上
 */
public class UsaElectricCooker {
    private UsaVoltage voltage;

    public UsaElectricCooker(UsaVoltage voltage) {
        this.voltage = voltage;
    }

    /**
     * 做饭
     */
    public void cook() {
        this.voltage.plug110();

        System.out.println("开始做饭...");
    }
}
